import React from 'react';
import PropTypes from 'prop-types';
import List from '@material-ui/core/List';
import Collapse from '@material-ui/core/Collapse';
class NestedList extends React.Component {
    render() {
        const {children} = this.props;
        return (
            <Collapse in={this.props.open} timeout="auto" unmountOnExit>
                <List component="div" disablePadding>
                    {children}
                </List>
            </Collapse>
        );
    }
}
NestedList.propTypes = {
    open: PropTypes.bool
};
export default NestedList;